﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace TTEngine
{
    public abstract class Condition
    {
        //consition name
        public string ConditionName { get; set; }

        //the actor who has this
        public Actor Actor { get; set; }

        //return a new instance
        public abstract Condition Clone();

        //per impulse processing
        public virtual void ProcessImpulse()
        {
        }

        //condition gained
        public virtual void ConditionAdded(Actor actor)
        {
            Actor = actor;
        }

        //condition removed
        public virtual void ConditionRemoved(Actor actor)
        {
            Actor = null;
        }

        //process speed
        public virtual int ProcessSpeed(int speed)
        {
            return speed;
        }
    }
}
